#ifndef MAINWINDOW_H
#define MAINWINDOW_H

#include <QMainWindow>

QT_BEGIN_NAMESPACE
namespace Ui { class MainWindow; }
QT_END_NAMESPACE

class MainWindow : public QMainWindow
{
    Q_OBJECT

public:
    MainWindow(QWidget *parent = nullptr);
    ~MainWindow();

private slots:
    void on_pushButtonHideFullScreen_clicked();

    void on_pushButtonChildFullScreen_clicked();

private:
    Ui::MainWindow *ui;

    // 子窗口全屏
    QWidget *fsWidget_ = nullptr;
    Qt::WindowFlags fsFlags_;

    void enableChildFullScreen();
    void disableChildFullScreen();

    // QWidget interface
protected:
    void keyPressEvent(QKeyEvent *event) override;

    // QObject interface
public:
    bool eventFilter(QObject *watched, QEvent *event) override;
};
#endif // MAINWINDOW_H
